//class for update queries function, by Fransiska Putri Wina
#ifndef MENU_UPDATE_QUERIES_H_ 
#define MENU_UPDATE_QUERIES_H_

#include <iostream>
#include <string>
#include <stdexcept>
#include <vector>
#include <time.h>
#include <algorithm>
//other types
#include "Category.h"
#include "Menu_Item.h"
#include "Recipe.h"
#include "Ingredient.h"
#include "Order.h"
#include "Order_Item.h"


class Menu_Update_Queries 
{
public:
    //default constructor
    Menu_Update_Queries();

     
		 
    //procedure for solving B3a problem, by Fransiska Putri Wina
	void B3a(vector<Menu_Item>,vector<Order_Item>&, vector<Order>);
		
	//procedure for solving C (delete order item) problem, by Muhammad Ghufron Mahfudhi
	void C_del_order_item (vector<Menu_Item>,vector<Order_Item>&);
      	
    /* 
	Add a new menu item using an existing recipe to an existing category (MGM B.3 b)
	The following code was modified by Eric Heisler in solving C3f. It now allows user
		to use a new recipe with a new menu item, which means the creation of new 
		ingredients that are being used by the new recipe, which is ultimately being 
		used by the new menu item
	*/
    void B3b_C3f (vector<Category> ,vector<Recipe>& , vector<Ingredient>&, vector<Menu_Item>& );
      	
    //procedure for solving B3c problem, by Eric Heisler
    void B3c(vector<Category>&);
      	
    //procedur for solving C3e problem, by Eric Heisler
    void C3e(vector<Order>&);
         
    /*
    The following method was written by Eric M Heisler, and solves Part C's delete function
    returns the index of the item to be deleted
    */
    int del_menu_item( vector<Menu_Item> );

	//getter
	vector<string> getNewCategories() const{return newCategories;};
	vector<string> getNewMenuItems() const{return newMenuItems;};
	vector<string> getNewRecipes() const{return newRecipes;};
	vector<string> getNewIngredients() const{return newIngredients;};
	vector<string> getNewOrders() const{return newOrders;};
	vector<string> getNewOrderItems() const{return newOrderItems;};

private:
	//MGM D.1
	vector<string> newCategories;
	vector<string> newMenuItems;
	vector<string> newRecipes;
	vector<string> newIngredients;
	vector<string> newOrders;
	vector<string> newOrderItems;
};
#endif //MENU_UPDATE_QUERIES_H_
